﻿@model Classified.Web.Models.SearchModel
@*@using (Html.BeginForm("SearchResult", "Home", FormMethod.Get, new { id = "SearchSubmit"}))
{*@
<div class="input-append pull-right">
    @Html.TextBoxFor(x => x.TextValue, new { placeholder = "SEARCH", @class = "input-lagre" })
    @Html.DropDownList("categoryId")
    @*<input type="submit" value="Search" class="btn" />*@
    <button class="btn" id="submit-btn">
        <i class="icon-search"></i>Search</button></div>
@* <a class="btn" href="javascript:void(0)" id="btnsearch"><i class="icon-search"></i>Search</a>*@
@*}*@
<script>
    $("#submit-btn").live("click", function () {
        var categoryId = $("#categoryId").val();
        var TextValue = $("#TextValue").val();

        var url = '/search-result/' + categoryId + '/' + TextValue;
        window.location.href = url;
        //        $("#SearchSubmit").submit();
    })
</script>
